package com.kongxx.struts2study.user.web.action;

import java.util.List;

import com.kongxx.struts2study.common.web.action.BaseAction;
import com.kongxx.struts2study.user.model.User;
import com.kongxx.struts2study.user.service.UserService;

public final class UserListAction extends BaseAction {

	private static final long serialVersionUID = 1L;
	
	private List<User> users;
	
	private UserService userService;
	
	@Override
	public String execute() throws Exception {
		users = userService.list();
		return SUCCESS;
	}

	public List<User> getUsers() {
		return users;
	}

	public void setUsers(List<User> users) {
		this.users = users;
	}

	public UserService getUserService() {
		return userService;
	}

	public void setUserService(UserService userService) {
		this.userService = userService;
	}	
}
